package com.ss.android.common.dialog;

import android.os.Message;
import android.view.View;

final class b implements View.OnClickListener {
    private final AlertController mAlertController;

    b(AlertController arg1) {
        this.mAlertController = arg1;

    }

    public final void onClick(View arg4) {
        Message v0;
        if (arg4 != this.mAlertController.mButtonPositive || this.mAlertController.mButtonPositiveMessage == null) {
            if (arg4 == this.mAlertController.mButtonNegative && this.mAlertController.mButtonNegativeMessage != null) {
                v0 = Message.obtain(this.mAlertController.mButtonNegativeMessage);
            } else if (arg4 == this.mAlertController.mButtonNeutral && this.mAlertController.mButtonNeutralMessage != null) {
                v0 = Message.obtain(this.mAlertController.mButtonNeutralMessage);
            } else {
                v0 = null;
            }
        } else {
            v0 = Message.obtain(this.mAlertController.mButtonPositiveMessage);
        }

        if (v0 != null) {
            v0.sendToTarget();
        }

        this.mAlertController.mHandler.obtainMessage(1, this.mAlertController.mDialogInterface).sendToTarget();
    }
}

